import request from '@/utils/request'

//查询医院基础信息列表
export function getHospSetList(current, limit, searchObj) {
  return request({
    url: `/admin/hosp/hospitalSet/findPageHospSet/${current}/${limit}`,
    method: 'post',
    data: searchObj
  })
}

//修改医院基础信息
export function editHospSet(data) {
  return request({
    url: '/admin/hosp/hospitalSet/updateHospitalSet',
    method: 'post',
    data: data
  })
}

//添加医院基础信息
export function addHospSet(data) {
  return request({
    url: '/admin/hosp/hospitalSet/saveHospitalSet',
    method: 'post',
    data: data
  })
}

//删除医院基础信息
export function delHospSet(id) {
  return request({
    url: `/admin/hosp/hospitalSet/${id}`,
    method: 'delete'
  })
}

//批量删除医院
export function batchDelHospSet(idList) {
  return request({
    url: '/admin/hosp/hospitalSet/batchRemove',
    method: 'delete',
    data: idList
  })
}

//启用或禁用医院
export function lockOrUnlockHospSet(id, status) {
  return request({
    url: `/admin/hosp/hospitalSet/lockHospitalSet/${id}/${status}`,
    method: 'put'
  })
}
